The present invention concerns a method and a device for adapting error protection in a communication network. It applies, in particular, to the transmission of data from a data server to at least one client via a packet transmission network subject to packet loss. For example, the network is a network implementing the IP Internet protocol for transporting IP packets. The network may be wired or wireless. Adapting error protection may comprise adapting error correction codes.
The present invention further concerns a method and device for detecting transition in the distribution law for losses of packets transmitted over a communication network and a method and device for protecting the transmitted data. It applies, in particular, to an adaptation of a level of redundancy, especially a level of error correcting codes, in a transmission of packets over a network subject to packet losses, whether or not it be a wired network.
The types of loss considered include:                losses due to congestion of the network: in this case, the quantity of data sent is too high and at least one router of the network loses a proportion of the packets it receives, and        losses due to interference, for example which may arise on a wireless link of the network due to extraneous microwaves.        
To take into account these losses, two types of protection are provided at the server. The first implements a congestion control algorithm. If loss notifications are received by the server, it may thus reduce the sending rate. Algorithms such as TCP (acronym for “Transmission Control Protocol”) and TFRC (acronym for “TCP Friendly Rate Control”) implement this strategy.
The second type of protection implements error correcting or “FEC” codes, (“FEC” for “Forward Error Correction”). An error correcting code enables redundancy packets to be generated from data packets to be able to restore erroneous received packets or lost packets. The FEC redundancy packets are coupled to the payload data to protect them by permitting their restoration in case of loss. The restoration succeeds if the rate of losses or errors remains below a certain limit, dependent on the level of redundancy generated.
Generally, the proportion of redundancy packets is increased when packet losses are detected.
Consequently, it is desirable to determine an appropriate level of redundancy. Too low a level corresponds to insufficient protection of the data. On the other hand, too high a level results in unnecessary congestion of the network by the redundancy packets.
Only packet losses are considered below, since erroneous packets received are eliminated and are thus also considered as being lost packets.
During a data transmission, the loss rate may strongly vary from one moment to the next. Moreover, to find the suitable level of redundancy and adapt it rapidly, it is necessary to rapidly detect strong variations in the loss rate.
It is important to determine the adequate proportion of redundancies, in particular during a period of congestion. This is because, as the available rate decreases in case of congestion, for example due to the implementation of one of the protocols TFRC or TCP, the quantity of data sent is reduced. If the information to transmit is video, this video must then be highly compressed to be sent in real time. Furthermore, if the proportion of redundancy packets is also increased, the compression rate of the video may become very high, which implies visible compression effects, such as block effects which may be unpleasant.
Consequently, to find the adequate proportion of redundancy packets during a period of congestion is important, in psycho-visual terms, when video data are transmitted.
The detection of a period of congestion is not instantaneous. Usually, the client detects the occurrence of packet loss and sends a loss notification back to the server. This implies a delay in the adaptation of the transmission rate and in the increase of the proportion of redundancies. This lag is due:                to the delay in detecting the lost packets that are identified as congestion losses, at the client,        to the delay in generating and transmitting the notification back from the client to the server, and        to the buffer of RTP packets that are already ready to be sent, which may not be sufficiently protected.        
On account of this lag, the proportion of lost packets may be very high at the start of a congestion phase. If these packets concern a real-time video stream, the visual effect may be disastrous.
Consequently, a known strategy consists of continuously providing a high proportion of redundancies to anticipate the occurrence of a congestion phase. However, during the congestion phases, this strategy imposes occupancy of the bandwidth by the redundancies which, by imposing a high compression rate, results in a lower image quality.
Consequently, a strategy which consists of adapting the proportion of redundancy packets during a congestion phase is preferable.
Document US 2006/0251011 describes a loss tolerant TCP algorithm, which means that redundancy packets are added to the payload data packets in windows of dimension W of the TCP protocol. To compute the ratio between the redundancy packets and the payload data packets in the current window, a loss rate is computed over the preceding window of dimension W. However, if the size of the windows is small, the ratio computed is unstable, like the rate of loss and, if the size of the windows is large, taking a congestion into account is delayed. The extrapolation over the preceding window does not reflect the real variations in the loss rate and the adaptation of the redundancy level to the loss rate is thus not fast enough.
Document PCT/US01/45222 proposes to adapt the protection by redundancies on the basis of the length of the periods of bursts of losses. However, burst periods are determined in the analog domain. This method cannot therefore be applicable in the case of IP/RTP packets.
Document U.S. Pat. No. 7,328,394 describes a module which adapts the FEC redundancy rate on the basis of a record which is composed of successive windows of fixed size. An FEC redundancy rate is tested and makes it possible to compute a rate of loss for each of the consecutive windows by simulating a correction by use of FEC redundancies. The final loss rate is determined by weighting the loss rates for each window, using a weighting which is inversely proportional to the age (period elapsed) of the window. The rate of redundancies which leads to the final target loss rate is selected. However, this module has the same drawbacks as the method described in document US 2006/0251011.